package com.my.hotel.mapper;

import com.my.hotel.entity.KfImg;
import com.my.hotel.util.ILog;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;
import org.springframework.stereotype.Repository;

@Repository
public interface KfImgMapper {
    @ILog("添加客房图片")
    @Insert("insert into tb_kf_img values(null,#{kfId},#{kfImgPath})")
    void addKfImg(KfImg kfImg);
    @Select("select * from tb_kf_img where kf_id=#{id}")
    KfImg getKfImg(int id);
    @Update("update tb_kf_img set kf_img_path=#{kfImgPath} where kf_id=#{kfId}")
    void update(KfImg kfImg);
}
